#pragma once

#include <iostream>

template<typename T>
class TrSingleton {
public:
    static T* instance() {
        static T instance;
        return &instance;
    }
    virtual ~TrSingleton() {}
    TrSingleton(const TrSingleton&) = delete;
    TrSingleton& operator =(const TrSingleton&) = delete;
protected:
    TrSingleton() {}
};